<template>
	<view class="personal">
		<scroll-view @scroll="scrolltoupperS" style="height: 100vh;" :scroll-top="scrollTop" scroll-y="true"
			class="scroll-Y u-skeleton">
			<!-- 导航 -->
			<u-navbar :is-back="false" title="个人中心" title-color="#3F3F3F" :title-bold="true" :border-bottom="false"
				:background="background"></u-navbar>
			<!-- 头部 -->
			<view class="headers">
				<!-- <image				
					src="https://beedao.oss-cn-beijing.aliyuncs.com/9ebad78caf474c938a9256b33a6c221f.png"
					mode=""
					style="width: 100%;height: 397rpx;position: absolute;top: 0;z-index: -99;"
				></image> -->
				<!-- <image src="../../static/icon/cs.png" mode="" class="background"></image> -->
				<view class="logins_s">
					<navigator class="intro  clearfix">
						<image v-if="userInfo && userInfo.portrait" :src="userInfo.portrait" mode="aspectFill"
							class="fl u-skeleton-circle"></image>
						<image v-else src="/static/icon/header.png" mode="widthFix" class="fl u-skeleton-circle">
						</image>
					</navigator>
					<view class="logins_s1" style="display: flex;justify-content: center;align-items: center;">
						<view>
							<view class="name u-skeleton-rect" style="padding: 6rpx 0;">
								{{ userInfo == '' ? 'bee到用户' : userInfo.nickname }}
							</view>
							<view class="u-skeleton-rect" v-if="userInfoVO.member">
								<image style="width: 60rpx;height: 30rpx;margin-left: 2rpx;"
									src="https://beedao.oss-cn-beijing.aliyuncs.com/9cd66885faab4b55af375ad7ad2211d7.png">
								</image>
							</view>
						</view>


					</view>
				</view>
			</view>
			<view class="balance " style="margin-bottom: 16rpx;">
				<view class="navigator" @click="card()">
					<view style="position: relative;">
						<!-- <image src="../../static/icon/kajuan.png" mode="" style="width: 40rpx;height: 40rpx;"
							class="u-skeleton-circle"></image>
						<view class="kajuan" style="" v-if="carnums.couponsCount != 0"></view> -->
						<view class="tit" style="color: #000000;font-size: 30rpx;line-height: 46rpx;font-weight: 500;">
							<text
								class="u-skeleton-rect">{{carnums.couponsCount > 99 ? "99+":carnums.couponsCount}}</text>
						</view>
						<view class="tit" style="color: #000000;font-size: 32rpx;font-weight: 500;line-height: 42rpx;">
							<text class="u-skeleton-rect">卡券</text>
						</view>
					</view>
				</view>
				<view class="navigator" @click="collet()">
					<view style="position: relative;">
						<!-- <image src="../../static/icon/shouc.png" mode="" style="width: 40rpx;height: 40rpx;"
							class="u-skeleton-circle"></image>
						<view class="shoucang" v-if="carnums.favoriteCount != 0">{{ carnums.favoriteCount }}</view>
						<view class="tit"><text class="u-skeleton-rect"></text></view> -->
						<view class="tit" style="color: #000000;font-size: 30rpx;line-height: 46rpx;font-weight: 500;">
							<text
								class="u-skeleton-rect">{{carnums.favoriteCount > 99 ? "99+" :carnums.favoriteCount}}</text>
						</view>
						<view class="tit" style="color: #000000;font-size: 32rpx;font-weight: 500;line-height: 42rpx;">
							<text class="u-skeleton-rect">收藏</text>
						</view>
					</view>
				</view>
				<!-- <view class="navigator" @click="auntCandidate()">
					<view>
						<view class="tit" style="color: #000000;font-size: 30rpx;line-height: 46rpx;font-weight: 500;">
							<text
								class="u-skeleton-rect">{{carnums.candidateCount > 99 ? "99+" :carnums.candidateCount}}</text>
						</view>
						<view class="tit" style="color: #000000;font-size: 32rpx;font-weight: 500;line-height: 42rpx;">
							<text class="u-skeleton-rect">候选阿姨</text></view>
					</view>
				</view> -->
				<view class="navigator" @click="information()">
					<view style="position: relative;">
						<!-- <image src="../../static/icon/xiaoxi.png" mode="" style="width: 40rpx;height: 40rpx;"
							class="u-skeleton-circle"></image> -->
						<view class="xiaoxi" v-if="total != '' || total != 0">
							<image style="width: 22rpx;height: 22rpx;"
								src="https://beedao.oss-cn-beijing.aliyuncs.com/5dc2a623f41e400b9e63c4fbce4d0244.png"
								mode=""></image>
						</view>
						<view class="tit" style="color: #000000;font-size: 30rpx;line-height: 46rpx;font-weight: 500;">
							<text class="u-skeleton-rect">{{total > 99 ? "99+" :total}}</text>
						</view>
						<view class="tit" style="color: #000000;font-size: 32rpx;font-weight: 500;line-height: 42rpx;">
							<text class="u-skeleton-rect">消息</text>
						</view>
					</view>
				</view>
			</view>
			<!-- end -->
			<!-- 会员 -->
			<view v-if="configForm.showMember == '1'" @click="goMember"
				style=" background-image: url(https://beedao.oss-cn-beijing.aliyuncs.com/bfbccac0190144beb4104e55ed981a51.png);    background-size: 100% 100%;background-repeat: no-repeat;width: 96%;margin: 0 auto;height: 200rpx;">
				<view style="display: flex;justify-content: space-between;width: 90%;margin: 0 auto;padding:40rpx 0 ;">
					<view>
						<view style="display: flex;margin-top: 10rpx;">
							<view>
								<image class="u-skeleton-rect" style="width: 80rpx;height: 36rpx;"
									src="https://beedao.oss-cn-beijing.aliyuncs.com/a1164faa7ae849a2ac1f4fd45735f3c5.png">
								</image>
							</view>
							<view v-if="userInfoVO.member" class="u-skeleton-rect"
								style="color: #FFFFFF;margin-left: 14rpx;">{{userInfoVO.money}}</view>
							<view v-else class="u-skeleton-rect" style="color: #FFFFFF;margin-left: 6rpx;">会员卡</view>
						</view>
						<view v-if="userInfoVO.member" class="u-skeleton-rect"
							style="color: #FFFFFF;margin-top: 10rpx;font-size: 27rpx;">
							您的会员将于{{userInfoVO.memberEnd}}到期</view>
						<view v-else class="u-skeleton-rect"
							style="color: #FFFFFF;margin-left: 6rpx;margin-top: 10rpx;font-size: 27rpx;">开通会员享受专属权益
						</view>

					</view>
					<view style="display: flex;justify-content: center;align-items: center;">
						<view class="u-skeleton-rect"
							style="padding: 16rpx 20rpx;background: #ECE2BA;border-radius: 20rpx;color: #040404;font-weight: 400;">
							查看权益</view>
					</view>
				</view>
			</view>
			<!-- 会员结束 -->

			<!-- 我的阿姨 -->
			<view v-if="carnums.haveMonthOrder == 1" class="order" @click="all()">
				<view class="my_order u-skeleton-rect">我的阿姨</view>
				<view class="all_order">
					<view class="text u-skeleton-rect" style="font-size: 26rpx;padding-right: 12rpx;">查看全部</view>
					<image src="../../static/icon/jian.png" mode=""></image>
				</view>
			</view>
			<view v-if="carnums.haveMonthOrder == 1" style="width: 100%;padding-top: 28rpx;">
				<scroll-view :scroll-x="true" scroll-left="0" @scroll="scrolltoupper"
					style="white-space: nowrap; display: flex;width: 100vw;" scroll-with-animation
					:scroll-left="slider.scrollLeft">
					<view style="padding-left: 30rpx;">
						<view
							style="border-radius: 20rpx; width: 682rpx;height: 166rpx;box-shadow: 0px 2rpx 10rpx rgba(0, 0, 0, 0.12);display: inline-block;margin-right: 20rpx;">
							<view style="display: flex;align-items: center;">
								<image style="width: 166rpx;height: 166rpx;" class="u-skeleton-circle" mode="aspectFill"
									:src="monthOrderInfo.portrait"></image>
								<view
									style="display: flex;justify-content: space-between;width: 500rpx;align-items: center;height: 166rpx;">
									<view style="margin-left:20rpx ;height: 166rpx;">
										<view style="overflow: hidden;margin-top: 22rpx;">
											<text class="u-skeleton-rect"
												style="float: left; font-size: 30rpx;color: #3F3F3F;">{{ monthOrderInfo.name }}</text>
											<text class="u-skeleton-rect"
												style="margin-left: 22rpx; border-radius: 13rpx; font-size: 26rpx;color: #F39E37;display: inline-block;background-color: #FFF6EB;width: 86rpx;height: 40rpx;line-height: 40rpx;text-align: center;float: left;">
												{{ monthOrderInfo.score || '0.0' }}分
											</text>
										</view>
										<view style="margin-top: 20rpx;">
											<text style="color: #3F3F3F;font-size:26rpx ;"
												class="u-skeleton-rect">{{ monthOrderInfo.businessName }}</text>
										</view>
									</view>
									<view
										style="color: #3F3F3F;font-size: 30rpx;margin-right:20rpx ;height: 166rpx;margin-top: 22rpx;">
										<text class="u-skeleton-rect"
											v-if="monthOrderInfo.orderStatus == 'WAIT_TAKE_FOR_INTERVIEW'">待接单</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'WAIT_INTERVIEW'">待面试</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'CHANGE_FOR_INTERVIEW'">更换员工待确认</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'WAIT_PAY_PRE'">待支付定金</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'PROBATION'">试岗中</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'WAIT_SIGN'">待签约</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'ON_SERVICE'">服务中</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == 'FINISH_SERVICE'">待评价</text>
										<text class="u-skeleton-rect"
											v-else-if="monthOrderInfo.orderStatus == ' ISSUE'">售后中</text>
									</view>
								</view>
							</view>
						</view>
					</view>

					<view v-if="defaultIndex != 100" class="underline"
						:style="'transform:translateX(' + slider.left + 'px);width:' + slider.width + 'px'"></view>
				</scroll-view>
				<!-- <scroll-view :scroll-x="true" scroll-left="0" @scroll="scrolltoupper"
					style="white-space: nowrap; display: flex;width: 100vw;" scroll-with-animation
					:scroll-left="slider.scrollLeft">
					<view style="padding:0 20rpx; border-radius: 4rpx; width: 220rpx;display: inline-block;"
						v-for="item in 6">
						<view style="text-align: center;background-color: #F9F9F9;padding: 16rpx 0;">
							<view style="width: 100%;text-align: center;">
								<image style="width: 100rpx;height: 100rpx;" :src="monthOrderInfo.portrait"></image>
							</view>
							<view style="display: flex;align-items: center;    justify-content: center;">
								<view
									style="padding: 6rpx 18rpx;background-color: #FF6060;color: #FFFFFF;border-radius: 24rpx;margin-top: -12rpx;">
									<text class="u-skeleton-rect"
										v-if="monthOrderInfo.orderStatus == 'WAIT_TAKE_FOR_INTERVIEW'">待接单</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'WAIT_INTERVIEW'">待面试</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'CHANGE_FOR_INTERVIEW'">更换员工待确认</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'WAIT_PAY_PRE'">待支付定金</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'PROBATION'">试岗中</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'WAIT_SIGN'">待签约</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'ON_SERVICE'">服务中</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == 'FINISH_SERVICE'">待评价</text>
									<text class="u-skeleton-rect"
										v-else-if="monthOrderInfo.orderStatus == ' ISSUE'">售后中</text>
								</view>

							</view>
							<view style="line-height: 42rpx;">{{ monthOrderInfo.name }}</view>
							<view style="line-height: 42rpx;">{{monthOrderInfo.businessName}}</view>
							<view style="color: #FF0000;font-size: 27rpx;line-height: 42rpx;">
								{{ monthOrderInfo.score || '0.0' }}分</view>
						</view>
					</view>
				</scroll-view> -->
			</view>
			<view></view>
			<!-- 订单 -->
			<view class="order" style="padding: 24rpx 30rpx;" @click="all2('', 0)">
				<view class="my_order u-skeleton-rect">我的订单</view>
				<view class="all_order">
					<view class="text u-skeleton-rect" style="font-size: 26rpx;padding-right: 12rpx;">查看全部</view>
					<image src="../../static/icon/jian.png" mode=""></image>
				</view>
			</view>
			<!-- 占位符 -->
			<view class="height"></view>
			<scroll-view :scroll-x="true" enhanced="true" show-scrollbar="false" @scroll="scrolltoupper" style="width: 100% ;white-space: nowrap;padding:42rpx 0rpx 20rpx 0rpx ;
				overflow: hidden;
				z-index: 99;" scroll-with-animation :scroll-left="slider.scrollLeft">

				<view class="status" style="display: inline-block;" @click="jumpToOrder('pays', 2)">
					<view style="width: 120rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/dc1289bc64b44351867c545eb9daec25.png"
							mode=""></image>
						<view v-if="carnums.pays !== 0"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 18rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.pays !== 0 && carnums.pays ? carnums.pays : '' }}
						</view>

					</view>
					<view><text class="u-skeleton-rect">待支付</text></view>
				</view>
				<view class="status" style="display: inline-block;" @click="jumpToOrder('fightGroup', 1)">
					<view style="width: 80rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/1b0452bee8ac42b899100ed3cd815cbc.png"
							mode=""></image>
						<view v-if="carnums.fightGroup !== 0 && carnums.fightGroup"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 4rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.fightGroup !== 0 && carnums.fightGroup ? carnums.fightGroup : '' }}
						</view>
					</view>
					<view><text class="u-skeleton-rect">拼团中</text></view>
				</view>
				<view class="status" style="display: inline-block;" @click="jumpToOrder('onServices', 3)">
					<view style="width: 80rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/169d70044ca34689b1bb27311a25fb8c.png"
							mode=""></image>
						<view v-if="carnums.onServices !== 0"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 4rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.onServices !== 0 && carnums.onServices ? carnums.onServices : '' }}
						</view>
					</view>
					<view><text class="u-skeleton-rect">进行中</text></view>
				</view>
				<view class="status" style="display: inline-block;" @click="jumpToOrder('waitAppraises', 4)">
					<view style="width: 80rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/ce7a430bb18844e497cc9a4a6869316b.png"
							mode=""></image>
						<view v-if="carnums.waitAppraises !== 0"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 4rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.waitAppraises !== 0 && carnums.waitAppraises ? carnums.waitAppraises : '' }}
						</view>
					</view>
					<view><text class="u-skeleton-rect">待评价</text></view>
				</view>
				<view class="status" style="display: inline-block;" @click="jumpToOrder('finishes', 5)">
					<view style="width: 80rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/65058634edb0411fb58d861b1ea8f360.png"
							mode=""></image>
						<view v-if="carnums.finishes !== 0"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 4rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.finishes !== 0 && carnums.finishes ? carnums.finishes : '' }}
						</view>
					</view>
					<view><text class="u-skeleton-rect">已完成</text></view>
				</view>

				<view class="status" style="display: inline-block;" @click="jumpToOrder('issues', 6)">
					<view style="width: 80rpx;position: relative;margin: auto;padding-top: 20rpx;">
						<image class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/1a239a246a424c89b209df49a89c0c11.png"
							mode=""></image>
						<view v-if="carnums.issues !== 0"
							style="background-color: #ffffff; position: absolute;top: 2rpx;right: 4rpx; font-size: 16rpx;color: #FF7300;text-align: center; width:30rpx ;height: 30rpx;text-align: center;border: 2rpx solid #FF7501;border-radius: 50%;line-height: 30rpx;">
							{{ carnums.issues !== 0 && carnums.issues ? carnums.issues : '' }}
						</view>
					</view>
					<view><text class="u-skeleton-rect">售后/退款</text></view>
				</view>
			</scroll-view>
			<view v-if="carnums.haveGroup == 1"
				style="width: 92%;margin: 0 auto;background-color: #FFF9F9;height: 90rpxmargin-top: 20rpx;font-size: 28rpx;">
				<view style="display: flex;align-items: center;display: flex;justify-content: center;">
					<view style="display: flex;align-items: center;justify-content: center;">
						<image style="height: 70rpx;width: 100rpx;" :src="carnums.groupBisIcon" mode="aspectFill">
						</image>
					</view>
					<view style="line-height: 90rpx;margin-left: 30rpx;">
						<text style="color:#000000 ;">我的拼团还差</text>
						<text style="color:#FF3D00 ;">1</text>
						<text style="color:#000000 ;">人，剩</text>
						<text
							style="color:#FF3D00 ;">{{countdown.hour}}:{{countdown.minute}}:{{countdown.second}}</text>
					</view>
					<view style="display: flex;align-items: center;justify-content: center;margin-left: 30rpx;">
						<button open-type="share"
							style="padding: 0;font-size: 26rpx;background-color: #EE0C00;color: #ffffff;border-radius: 14rpx;width: 140rpx;height: 60rpx;line-height: 60rpx;text-align: center;">立即邀请</button>
					</view>
				</view>

			</view>
			<!-- 占位符 -->
			<view class="height" style="margin-top: 28rpx;"></view>
			<view class="order" style="padding: 24rpx 30rpx 0rpx 30rpx;">
				<view class="my_order u-skeleton-rect">我的工具</view>
			</view>
			<!-- 功能列表 -->
			<view class="nav">
				<u-grid :col="4" :border="false">
					<u-grid-item @click="customer()">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/1e1f93b1ff1e47448c4cf38ae3194c00.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">在线客服</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="please()" v-show="configForm.showInvite == '1'">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/a88260d48edb47b69382b014d25d19f0.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">邀请赚钱</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="address()">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/f35deb05ab714319a6357907ae3ff668.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">家庭地址</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="idea()">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/83f7f89d611c4ec8804b4d2fa06262fe.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">意见反馈</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="jumpToShop()">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/1561059defb64096b6bd46ed28716af6.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">商家入驻</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="about()">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/7b48480a3db14ef4907276950da491ab.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">关于我们</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="goRecruit(1)" v-show="configForm.showLeaderRecruit == '1'">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/de0f8cd1bf94440cb82701ba22bd9101.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">团长招募</text>
						</view>
					</u-grid-item>
					<u-grid-item @click="goRecruit(2)" v-show="configForm.showLeaderMarketing == '1'">
						<image style="width: 70rpx;height: 70rpx;" class="u-skeleton-circle"
							src="https://beedao.oss-cn-beijing.aliyuncs.com/9d43c79a16494df993e03ec953abddee.png"
							mode="widthFix"></image>
						<view
							style="font-size:28rpx;color: #000;font-weight: 400;text-align: center;line-height: 60rpx;">
							<text class="u-skeleton-rect">团长营销</text>
						</view>
					</u-grid-item>

				</u-grid>
				<u-toast ref="uToast" />
				<!-- <view class="heights"></view> -->
			</view>
			<!-- end -->
		</scroll-view>
		<!--引用组件-->
		<u-skeleton :loading="loading" :animation="true" bgColor="#FFF"></u-skeleton>
	</view>

</template>

<script>
	export default {
		data() {
			return {
				timerFun: null,
				userInfoVO: {}, //用户信息
				loading: true,
				istrue: true,
				monthOrderInfo: {},
				background: {
					backgroundColor: 'rgba(255,255,255,0)'
					// opacity: 1
				},
				balances: '',
				userInfo: '',
				pageSize: 10,
				page: 1,
				total: 0,
				carnums: {
					couponsCount: 0,
					favoriteCount: 0,
					candidateCount: 0,
					onServices: 0,
					confirms: 0,
					waitAppraises: 0,
					finishes: 0,
					issues: 0,
					pays: 0
				},
				slider: {
					left: 0,
					width: 0,
					scrollLeft: 0
				},
				token: '',
				userId: '',
				configForm: {}, //小程序配置
				countdown: {
					nowTime: 0,
					hour: 0,
					minute: 0,
					second: 0
				},
				isIos: 1, //是否为ios
			};
		},
		onLoad(option) {
			var parentId = option.parentId;
			if (parentId) {
				uni.setStorageSync('parentId', parentId);
				uni.navigateTo({
					url: '../login/login'
				})
				return false;
			}
			this.token = uni.getStorageSync('token');
			if (this.token) {
				var userInfo = JSON.parse(uni.getStorageSync('userinfo'));
				this.userInfo = userInfo;
			}
			let that = this;
			uni.getSystemInfo({
				success: function(res) {
					if (res.platform == "ios") {
						that.isIos = 1;
					} else {
						that.isIos = 0;
					}
				}
			});
		},
		onShow() {
			if (this.timerFun) {
				clearInterval(this.timerFun)
			}

			this.token = uni.getStorageSync('token');
			if (!this.token) {
				uni.hideShareMenu();
				this.loading = false;
			} else {
				uni.showShareMenu();
			}

			this.getMessage();
			this.getTime(); //获取时间

			// 获取小程序功能配置
			this.getConfig();
		},
		onHide() {
			clearInterval(this.timerFun)
		},
		methods: {
			//获取时间
			getTime() {
				let opts = {
					way: true, //true JSON请求；false 表单请求
					method: 'post',
					url: 'common/time'
				};
				let data = {};
				this.http.httpTokenRequest(opts, data).then(res => {
					if (res.code == '200') {
						this.countdown.nowTime = res.data;
						this.car_num();
					}
				})
			},
			// 获取小程序功能配置
			getConfig() {
				var _this = this;
				let opts = {
					way: true, //true JSON请求；false 表单请求
					method: 'post',
					url: 'system-config/applet'
				};
				let data = {};
				_this.http.httpTokenRequest(opts, data).then(res => {
					if (res.code == "200") {
						_this.configForm = res.data;
					}
				});
			},
			onShareAppMessage(res) {
				if (this.carnums.haveGroup == 1) {
					return {
						title: "平台补贴 日常保洁（服务类型）拼团下单，就差1人拼成。",
						imageUrl: this.carnums.groupBisIcon,
						path: '/pageageA/placeOrder/appointment?orderId=' + this.carnums.groupOrderId + '&groupType=' + 2
					};
				} else {
					var userInfo = JSON.parse(uni.getStorageSync('userinfo'));
					this.userId = userInfo.userId;
					if (res.from === 'button') {
						// 来自页面内分享按钮
					}
					let opts = {
						way: true, //true JSON请求；false 表单请求
						method: 'post',
						url: 'common/insertShareLog'
					};
					let data = {};
					this.http.httpTokenRequest(opts, data).then(res => {
						//分享日志，不需要处理
					});
					return {
						title: '必到家政',
						path: '/pages/login/login?id=' + this.userId + "&jumpType=" + 4
					};
				}

			},
			// 分享到朋友圈
			onShareTimeline() {
				var userInfo = JSON.parse(uni.getStorageSync('userinfo'));
				this.userId = userInfo.userId;
				let opts = {
					way: true, //true JSON请求；false 表单请求
					method: 'post',
					url: 'common/insertShareLog'
				};
				let data = {};
				this.http.httpTokenRequest(opts, data).then(res => {
					//分享日志，不需要处理
				});
				return {
					title: '必到家政',
					query: 'parentId=' + this.userId
					// imageUrl:'https://beedao.oss-cn-beijing.aliyuncs.com/cca1cf07545140e6b44c42f1c9b861d8.png',
					// path: '/pages/home/home?parentId=' + this.userId
				};
			},
			// 登录判断
			islogin() {
				uni.showModal({
					title: '登录提示',
					content: '该功能需要登录后使用。',
					confirmText: '去登录',
					success: function(res) {
						if (res.confirm) {
							if (this.timerFun) {
								clearInterval(this.timerFun)
							}
							uni.navigateTo({
								url: '/pages/login/login'
							});
						} else if (res.cancel) {}
					}
				});
				return;
			},
			scrolltoupperS(e) {
				if (e.detail.scrollTop > 10) {
					this.background.backgroundColor = 'rgba(255,255,255,1)';
				} else {
					this.background.backgroundColor = 'rgba(255,255,255,0)';
				}
			},
			scrolltoupper(e) {
				if (e.detail.scrollLeft > 20) {
					this.istrue = false;
				} else {
					this.istrue = true;
				}
			},
			//去团长招募
			goRecruit(type) {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					if (type == 1) {
						// 团长招募
						uni.navigateTo({
							url: "/pageageA/personal/recruit"
						})
					} else {
						// 团长营销
						uni.navigateTo({
							url: "/pageageA/personal/marketing"
						})
					}
					if (that.timerFun) {
						clearInterval(that.timerFun)
					}
				}

			},
			all() {
				var that=this;
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return false;
				}
				that.$member.setMemberObj({
					tap: 'all'
				});
				if (that.timerFun) {
					clearInterval(that.timerFun)
				}
				uni.navigateTo({
					url: '../order/index'
				});
			},
			all2(val) {
				var that=this;
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return false;
				}
				that.$member.setMemberObj({
					tap: 'all'
				});
				if (that.timerFun) {
					clearInterval(that.timerFun)
				}
				uni.navigateTo({
					url: '../order/index2?type=' + val
				});
			},
			jumpToOrder(val, current) {
				var that=this;
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return false;
				}
				that.$member.setMemberObj({
					tap: val
				});
				if (that.timerFun) {
					clearInterval(that.timerFun)
				}
				uni.navigateTo({
					url: '../order/index2?type=' + val + '&current=' + current
				});
			},
			// 卡券
			card() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					if (that.timerFun) {
						clearInterval(that.timerFun)
					}
					uni.navigateTo({
						url: '../../pageageA/personal/card'
					});
				}
			},
			// 收藏
			collet() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					if (that.timerFun) {
						clearInterval(that.timerFun)
					}
					uni.navigateTo({
						url: '../../pageageA/personal/collet'
					});
				}
			},
			// 候选阿姨
			auntCandidate() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					if (that.timerFun) {
						clearInterval(that.timerFun)
					}
					uni.navigateTo({
						url: '../../pageageA/home/matching/auntCandidate/auntCandidate'
					});
				}
			},
			// 消息
			information() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								if (that.timerFun) {
									clearInterval(that.timerFun)
								}
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					if (that.timerFun) {
						clearInterval(that.timerFun)
					}
					uni.navigateTo({
						url: '../../pageageA/home/information/information'
					});
				}
			},
			// 在线客服
			customer() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/personal/customer'
					});
				}
			},
			// 邀请赚钱
			please() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/personal/please'
					});
				}
			},
			// 家庭地址
			address() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/personal/address'
					});
				}
			},
			// 意见反馈
			idea() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/personal/idea'
					});
				}
			},
			// 去开通会员
			goMember() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/member/meCenter'
					});
				}
			},
			// 关于我们
			about() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					clearInterval(that.timerFun)
					uni.navigateTo({
						url: '../../pageageA/personal/about'
					});
				}
			},
			// 商家入驻
			jumpToShop: function() {
				var that=this;
				that.token = uni.getStorageSync('token');
				if (!that.token) {
					uni.showModal({
						title: '登录提示',
						content: '该功能需要登录后使用。',
						confirmText: '去登录',
						success: function(res) {
							if (res.confirm) {
								clearInterval(that.timerFun)
								uni.navigateTo({
									url: '/pages/login/login'
								});
							} else if (res.cancel) {}
						}
					});
					return;
				} else {
					let opts = {
						way: true, //true JSON请求；false 表单请求
						method: 'post',
						url: 'user/center/getResults'
					};
					let data = {};
					that.http.httpTokenRequest(opts, data).then(res => {
						//打印请求返回的数据
						if (res.code == '200') {
							clearInterval(that.timerFun)
							uni.navigateTo({
								url: '../../pageageA/personal/ruzhu?status=' + res.data.status
							});
						} else if (res.code == '1081') {
							clearInterval(that.timerFun)
							uni.navigateTo({
								url: '../../pageageA/personal/shop'
							});
						} else {
							that.$refs.uToast.show({
								title: res.message,
								type: 'error'
							});
						}
					});
				}
			},

			// 卡券和收藏数量
			car_num() {
				var _this = this;
				clearInterval(_this.timerFun)
				let opts = {
					way: true, //true JSON请求；false 表单请求
					method: 'post',
					url: 'user/info'
				};
				let data = {};
				_this.http.httpTokenRequest(opts, data).then(res => {
					if (res.code == "200") {
						_this.carnums = res.data;
						clearInterval(_this.timerFun)
						if (_this.carnums.haveGroup == 1) {
							this.timerFun = setInterval(
								function() {
									_this.countdown.nowTime = _this.countdown.nowTime + 1000;
									_this.countDown();
								}, 1000)
						}

						_this.monthOrderInfo = res.data.monthOrderInfo;
						_this.userInfoVO = res.data.userInfoVO;
						_this.loading = false;

					} else {
						clearInterval(_this.timerFun)
						_this.loading = false;
					}
				});
			},
			addZero(num) {
				if (parseInt(num) < 10) {
					num = '0' + num;
				}
				return num;
			},
			countDown() {
				let that = this
				var times = "";
				if (that.isIos == "1") {
					times = Date.parse(new Date(that.carnums.groupEndTime.replace(/-/g, "/")));
				} else {
					times = Date.parse(new Date(that.carnums.groupEndTime));
				}
				var diff = times - that.countdown.nowTime;
				that.countdown.hour = that.addZero(Math.floor((diff / (1000 * 60 * 60) % 24)));
				that.countdown.minute = that.addZero(Math.floor((diff / (1000 * 60) % 60)));
				that.countdown.second = that.addZero(Math.floor((diff / 1000 % 60)));

				if (that.countdown.hour <= 0 && that.countdown.minute <= 0 && that.countdown.second <= 0) {
					that.countdown.hour = '00';
					that.countdown.minute = '00';
					that.countdown.second = '00';
					clearInterval(this.timerFun)
				}
			},
			//获取消息数量
			getMessage() {
				var _this = this;
				let opts = {
					way: true, //true JSON请求；false 表单请求
					method: 'post',
					url: 'message/getUnreadCount'
				};
				let data = {
					pageIndex: this.page,
					pageSize: this.pageSize
				};
				this.http.httpTokenRequest(opts, data).then(res => {
					_this.total = res.data;
				});
			}
		}
	};
</script>
<style>
	.nav .u-grid-item-box {
		padding: 0rpx 0 0 0 !important;
		margin-top: 38rpx;
	}
</style>
<style scoped lang="scss">
	.nav {
		width: 98%;
		margin: 0 auto;
		padding: 10rpx 0 30rpx 0;
	}

	.headers {
		width: 100%;
		height: 280rpx;
	}

	.css_one {
		left: 0;
	}

	.css_two {
		right: 0;
	}

	.headers .intro {
		overflow: hidden;
		color: #fff;
		font-size: 30rpx;
		line-height: 42rpx;
	}

	.headers .intro image {
		width: 130rpx;
		height: 130rpx !important;
		border-radius: 100%;
		background-size: cover;
		background-position: center 0;
		margin-top: 15rpx;
	}

	.headers .background {
		width: 100%;
		position: absolute;
		top: var(--status-bar-height + 40);
		z-index: -1;
		height: 268rpx;
	}

	.balance {
		width: 100%;
		// height: 118rpx;
		display: flex;
		color: #000000;
		font-size: 36rpx;
		line-height: 50rpx;
		text-align: center;
		background-color: #fff;
		// border-radius: 26rpx;
		margin: 0 auto;
		// border-bottom: 1rpx solid #eeeeee;
		// box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.14);
		margin-top: -100rpx;
		border-top: 4rpx solid #F6F6F6;
		border-bottom: 4rpx solid #F6F6F6;
		padding-bottom: 20rpx;
	}

	.balance>.navigator {
		width: 49.5%;
		margin-top: 22rpx;
	}

	.balance>.navigator .tit {
		font-size: 30rpx;
		line-height: 33rpx;
		color: #000000;
		font-family: PingFang SC;
		font-weight: 500;
	}

	.balance>.navigator .text-num {
		color: #fca800ff;
		font-size: 34rpx;
	}

	.nav {
		margin: 0 auto;
	}

	.nav .nav-list {
		background-color: #ffffff;
	}

	.nav .nav-list .navigator {
		padding: 0 40rpx 0 48rpx;
	}

	.nav .nav-list .navigator>view {
		font-size: 34rpx;
		font-weight: 500;
		color: #666;
		height: 100rpx;
		line-height: 105rpx;
		border-bottom: 1rpx solid #dfdfdf;
	}

	.nav .nav-list .navigator>view:last-child {
		border: 0 none;
	}

	.nav .nav-list .navigator>view .fr {
		margin-right: 0;
		margin-top: 40rpx;
		width: 13rpx;
	}

	// .logins{

	// 	display: flex;align-items: center;justify-content: space-between;padding: 0 32rpx;
	// }
	.logins_s {
		display: flex;
		padding: 0rpx 32rpx;
	}

	.logins_s1 {
		padding: 0rpx 0 0 32rpx;
	}

	.logins_s1 .name {
		font-size: 32rpx;
		color: #3f3f3f;
		font-weight: bold;
	}

	.clearfixs {
		display: flex;
		justify-content: space-between;
		align-items: center;
	}

	.clearfixs .c_img {
		width: 14rpx;
		height: 25rpx;
	}

	.clearfixs_s {
		display: flex;
		align-items: center;
	}

	.clearfixs_s .fls {
		font-size: 30rpx;
		color: #000;
		font-weight: 400;
	}

	.clearfixs_s image {
		width: 52rpx;
		height: 52rpx;
		margin-right: 30rpx;
	}

	.header {
		width: 100%;
		background: #fca800;
		position: fixed;
		top: 0;
		// left: 0;
		// z-index: 100;
		// display: flex;
		// align-items: baseline;
		// justify-content: space-between;
		height: 120rpx;
	}

	.header view {
		width: 25%;
		margin: 0 auto;
		margin-top: 20rpx;
		text-align: center;
	}

	.header text {
		font-size: 26rpx;
		line-height: 150rpx;
		font-family: PingFang SC;
		font-weight: bold;
		color: #3f3f3f;
		opacity: 0.9;
	}

	.order {
		display: flex;
		justify-content: space-between;
		padding: 14rpx 30rpx 10rpx 30rpx;
	}

	.order .my_order {
		font-size: 30rpx;
		color: #000000;
		font-weight: 500;
	}

	.order .all_order {
		display: flex;
		align-items: center;
	}

	.order .all_order image {
		width: 14rpx;
		height: 25rpx;
	}

	.order .all_order .text {
		font-size: 30rpx;
		color: #7a7a7a;
		padding-right: 28rpx;
		line-height: 16rpx;
	}

	.border {
		height: 2rpx;
		width: 100%;
		background-color: #f6f6f6;
	}

	.height {
		height: 4rpx;
		width: 100%;
		background-color: #f6f6f6;
	}

	.heights {
		height: 80rpx;
		width: 100%;
	}

	// .dingdan {
	// 	display: flex;
	// 	justify-content: space-around;
	// 	padding: 32rpx 12rpx;
	// 	text-align: center;
	// }
	// .dingdan {
	// 	display: flex;
	// 	justify-content: space-between;
	// }

	.status {
		width: 140rpx;
		text-align: center;
	}

	.status image {
		width: 60rpx;
		height: 60rpx;
	}

	.status view {
		font-size: 26rpx;
		font-weight: 500;
		color: #000000;
		margin-top: 10rpx;
	}

	.status .tips {
		width: 16rpx;
		height: 16rpx;
		border-radius: 50%;
		background: #fa5151ff;
		position: relative;
		bottom: 80%;
		left: 80%;
		opacity: 1;
	}

	.kajuan {
		width: 22rpx;
		height: 22rpx;
		background-color: #fe421c;
		border-radius: 16rpx;
		position: absolute;
		top: -3rpx;
		right: 58rpx;
		border: 2rpx solid #ffffff;
	}

	.shoucang {
		width: 42rpx;
		height: 28rpx;
		background-color: #fe421c;
		border-radius: 16rpx;
		position: absolute;
		border: 2rpx solid #ffffff;
		right: 40rpx;
		line-height: 24rpx;
		text-align: center;
		top: -6rpx;
		font-size: 20rpx;
		color: #ffffff;
		font-weight: 400;
	}

	.xiaoxi {
		// width: 42rpx;
		// height: 28rpx;
		// background-color: #fe421c;
		// border-radius: 16rpx;
		position: absolute;
		// border: 2rpx solid #ffffff;
		right: 86rpx;
		// line-height: 24rpx;
		// text-align: center;
		top: -16rpx;
		// font-size: 20rpx;
		// color: #ffffff;
		// font-weight: 400;
	}
</style>
